{template header}
<script src="static/bootstrap/js/utils.js"></script>
<link rel="stylesheet" href="static/calendar/js/calendar.css" />
<script type="text/javascript" charset="utf-8" src="static/calendar/calendar.php"></script>
<script src="{$staticHost}js/ColorPicker.js"></script>
<style type="text/css">
   .pad5 {padding-top: 10px;}
   .pad-left10 {padding-left: 10px;}
   .label-in-control {float: left;padding-top: 5px;text-align: right;width: 50px;}
   .label-in-control input {width: 50px;}
   .control-in-controls {margin-left: 70px;padding-top: 5px;}
   .control-in-controls input {width: 500px;}
   .control-group .controls label{float:left; margin-right: 10px;}

 
</style>

<form class="form-horizontal" action="index.php?c=admin&a=orderAction" method="post" enctype="multipart/form-data">
  <div class="control-group">
    <label class="control-label">订单状态</label>
    <div class="controls">
      <select name="status">
        {loop $orderStatus $k $v}
        <option value="{$k}" {if $k==$orderInfo['status']}selected{/if}>{$v}</option>
        {/loop}
      </select>
    </div>
  </div>
  <dl class="dl-horizontal">
      <dt>订单编号</dt>
      <dd><input type="text" readonly name="order_id" value="{$orderInfo['order_id']}"></dd>
      
      <dt>用户信息</dt>
      <dd>昵称：{$orderInfo['user']['nickname']}&nbsp;UID：{$orderInfo['uid']}</dd>
      
      <dt>商品信息</dt>
      <dd>
        <table>
          <thead>
            <tr>
              <th>货号</th>
              <th>商品名称</th>
              <th>规格</th>
              <th>数量</th>
              <th>单价</th>
              <th>总价</th>
            </tr>
          </thead>
          <tbody>
            {loop $orderInfo['goodsList'] $goods}
            <tr>
              <td>{$goods['product']['code']}</td>
              <td>{$goods['product']['title']}</td>
              <td>{$goods['goodsInfo']['attrPathName']}</td>
              <td>{$goods['goodsInfo']['num']}</td>
              <td>{$goods['goodsInfo']['price']}</td>
              <td>{eval echo $goods['goodsInfo']['num']*$goods['goodsInfo']['price']}</td>
            </tr>
            {/loop}
          </tbody>
        </table>
      </dd>
      
      <dt>金额</dt>
      <dd>{$orderInfo['total_fee']}</dd>
  </dl>
  <fieldset>
    {if $orderInfo['act_type']==8}
    <legend>识货下单信息</legend>
    <div class="control-group">
      <label class="control-label">订单号</label>
      <div class="controls">
        $haitaoInfo['child_orderno']
      </div>
    </div>
    <div class="control-group">
    <label class="control-label">订单状态</label>
    <div class="controls">
      $haitaoInfo['status_txt']
    </div>
    </div>
    <div class="control-group">
    <label class="control-label">备注</label>
    <div class="controls">
      $haitaoInfo['remark']
    </div>
    </div>
    {/if}

  <legend>收货信息</legend>
  <div class="control-group">
    <label class="control-label">姓名</label>
    <div class="controls">
      <input name="name" value="{$orderInfo['name']}">
    </div>
  </div>
  <div class="control-group">
    <label class="control-label">省</label>
    <div class="controls">
      <input name="province" value="{$orderInfo['province']}">
    </div>
  </div>
  <div class="control-group">
    <label class="control-label">市</label>
    <div class="controls">
      <input name="city" value="{$orderInfo['city']}">
    </div>
  </div>
  <div class="control-group">
    <label class="control-label">区</label>
    <div class="controls">
      <input name="district" value="{$orderInfo['district']}">
    </div>
  </div>
  <div class="control-group">
    <label class="control-label">地址</label>
    <div class="controls">
      <input name="address" value="{$orderInfo['address']}">
    </div>
  </div>
  <div class="control-group">
    <label class="control-label">手机</label>
    <div class="controls">
      <input name="phone" value="{$orderInfo['phone']}">
    </div>
  </div>
  </fieldset>
  <fieldset>
  <legend>物流信息</legend>
  <div class="control-group">
    <label class="control-label">选择物流</label>
    <div class="controls">
      <select name="shipping_id">
        {loop $logisticsTepList $v}
        <option value="{$v['id']}" {if $v['id'] == $orderInfo['shipping_id'] }selected{/if}>{$v['title']}</option>
        {/loop}
      </select>
    </div>
  </div>
  <div class="control-group">
    <label class="control-label">运单号</label>
    <div class="controls">
      <input type="text" name="shipping_num" value="{$orderInfo['shipping_num']}">
    </div>
  </div>
  </fieldset>
  <dl class="dl-horizontal">
      <dt>其他信息</dt>
      <dd>
        <table>
          <tr>
            <td>运费</td>
            <td>$orderInfo['shipping_fee']</td>
          </tr>
          <tr>
            <td>订单类型</td>
            <td>
            {if $orderInfo['match_id']}
            赛事
            {elseif $orderInfo['act_type'] == 2}
            马拉松
            {else}
            群组活动
            {/if}
            </td>
          </tr>
          <tr>
            <td>订单来源</td>
            <td>
            {if $orderInfo['match_id']}
            {$orderInfo['match_id']}
            {elseif $orderInfo['act_type'] == 2}
            {$orderInfo['act_id']}
            {else}
            {$orderInfo['aid']}
            {/if}
            </td>
          </tr>
          <tr>
            <td>支付状态</td>
            <td>{eval echo $payStatus[$orderInfo['pay_status']]}</td>
          </tr>
          <tr>
            <td>支付时间</td>
            <td>{eval echo date('Y-m-d H:i:s',$orderInfo['paytime'])}</td>
          </tr>
          <tr>
            <td>支付方式</td>
            <td></td>
          </tr>
          <tr>
            <td>支付流水号</td>
            <td></td>
          </tr>
          <tr>
            <td>发货时间</td>
            <td></td>
          </tr>
          <tr>
            <td>完成时间</td>
            <td></td>
          </tr>
          <tr>
            <td>完成方式</td>
            <td></td>
          </tr>
          <tr>
            <td>关闭时间</td>
            <td></td>
          </tr>
          <tr>
            <td>关闭原因</td>
            <td>
            {if $orderInfo['status'] == 3}
            手动取消
            {elseif $orderInfo['status'] == 4}
            订单完成
            {/if}
            </td>
          </tr>
        </table>
      </dd>
  </dl>
  

  
  <div class="control-group">
    <div class="controls">
        <input type="hidden" name="id" value="{$orderInfo['id']}">
        <input type="hidden" name="action_id" value="{$orderInfo['action_id']}">
        <button type="submit" class="btn">提交</button>
    </div>
  </div>
</form>
{template footer}